function res=An(lambda_in,x_in,n,xi,chi,mulambda,alpha,v,mux,rho,phi,ngridpoints)

temp_coef=fliplr(phi*(1-rho.^(0:n-1))/(1-rho)-1);

res=compute_exp(lambda_in,x_in,n,temp_coef,xi,chi,mulambda,alpha,v,mux,rho,phi,ngridpoints);